<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/common/includes.jsp" %>

<!DOCTYPE html>
<html lang="${currentLocale}">

<head>
	<title>zzzzzz - 发表</title>
	<%@ include file="/WEB-INF/common/meta.jsp" %>
	<%@ include file="/WEB-INF/common/global_res.jsp" %>
	<script type="text/javascript" src="<c:url value="/res/validate/jquery.validate.min.js" />"></script>
	<script type="text/javascript" src="<c:url value="/res/validate/messages_zh_CN.js" />"></script>
</head>
<body>

<%@ include file="/WEB-INF/common/header.jsp" %>

<div class="container">
	<div class="row">
		<div class="span9">
			<div class="row-fluid">
				<div class="span12">
					<ul class="nav nav-tabs">
					    <li class="active">
					    	<a href="${ctx}">文字</a>
					    </li>
					    <li>
					    	<a href="${ctx}">图文</a>
					    </li>
					    <li>
					    	<a href="${ctx}">观后感</a>
					    </li>
					 </ul>
					<div class="row-fluid">
				        <div class="span12">
							<c:url var="actionUrl" value="/topic/add" />
							<form:form id="topicForm" action="${actionUrl}" method="post" modelAttribute="topicForm" enctype="multipart/form-data" class="form-horizontal">
							<fieldset>
								<div class="control-group">
									<form:label path="title">标题</form:label>
									<form:input path="title" cssClass="input-large" placeholder="标题"  />
									<form:errors path="title" cssClass="text-error" />
								</div>
								<div class="control-group">
									<form:label path="textS">文章</form:label>
									<form:textarea path="textS" placeholder="简介" cssStyle="width:600px; height:400px;" />
									<form:errors path="textS" cssClass="text-error" />
								</div>
								<div class="control-group">
									<form:label path="tags">标签</form:label>
									<form:input path="tags" cssClass="input-large" placeholder="标签" />
									<form:errors path="tags" cssClass="text-error" />
								</div>
								<div class="control-group">
								  <div class="controls">
								    <button type="submit" class="btn">提交</button>
								  </div>
								</div>
							</fieldset>
							</form:form>
						</div>
					</div>
				</div>
			</div>
		</div>
		<div class="span3 rightbox">
				<div class="row-fluid">
					<div class="span12">
						<p style="padding-bottom: 20px;"><img src="${ctx}/res/imgs/test/1.jpg" alt="" class="pull-right"></p>
						<p><img src="${ctx}/res/imgs/test/2.jpg" alt="" class="pull-right"></p>
					</div>
				</div>
			</div>
	</div>
</div>

<%@ include file="/WEB-INF/common/footer.jsp" %>
</body>

<script type="text/javascript" src="${ctx}/res/kindeditor/kindeditor-min.js"></script>

<script>

var editorTextS;
KindEditor.ready(function(K) {
	editorTextS = K.create('textarea[name="textS"]', {
		resizeType : 1,
		allowImageUpload : false,
		allowPreviewEmoticons : false,
		allowFlashUpload : false,
		items : [
			'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline',
			'removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
			'insertunorderedlist', '|', 'emoticons', 'link']
	});
});

</script>

</html>